<%@ page language="java" contentType="text/html; charset=UTF-8"
         pageEncoding="UTF-8" %>
<%@ taglib uri="http://java.sun.com/jsp/jstl/core" prefix="c" %>
<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">
<html>
<head>
    <%
        String path = request.getContextPath();
        String basePath = request.getScheme() + "://" + request.getServerName() + ":" + request.getServerPort();
    %>
    <meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
    <title>支付</title>
    <style type="text/css">
        .hhh {
            background: url(<%=basePath%>/img/zfb.png);
            height: 500px;
            background-repeat: no-repeat;
            margin-top: 10px;
            margin-left: 500px;
        }
    </style>
<%--    <link rel="stylesheet" href="<%=basePath%>/css/bootstrap.min.css"/>--%>
    <link rel="stylesheet" href="https://stackpath.bootstrapcdn.com/bootstrap/3.4.1/css/bootstrap.min.css"
          integrity="sha384-HSMxcRTRxnN+Bdg0JdbxYKrThecOKuH5zCYotlSAcp1+c8xmyTe9GYg1l9a69psu" crossorigin="anonymous">
</head>
<body>
<%--<script type="text/javascript" src="js/jquery-2.0.3.min.js"></script>--%>
    <script src="https://s3.pstatp.com/cdn/expire-1-M/jquery/3.2.1/jquery.min.js"></script>
<%--	<script type="text/javascript" src="js/bootstrap.min.js"></script>--%>
<script src="https://stackpath.bootstrapcdn.com/bootstrap/3.4.1/js/bootstrap.min.js" integrity="sha384-aJ21OjlMXNL5UyIl/XNwTMqvzeRMZH2w8c5cRVpzpU8Y5bApTppSuUkhZXN0VxHd" crossorigin="anonymous"></script>

<jsp:include page="header1.jsp"></jsp:include>
<div style="margin-left: 650px; margin-top: 160px">
    <table>
        <td style="width: 400px">订单编号：${order.ordernum}</td>
        <td style="width: 400px">创建时间：${order.time}</td>
    </table>
</div>

<div class="hhh">
    <br> <br> <br> <br> <br>
    <div style="margin-left: 355px">
        <strong><span
                style="color: rgb(255, 102, 0); font-size: 30px;">${order.money}</span></strong>
    </div>
</div>
<input type="button" onclick="buy('${order.ordernum}')" value="假装付款">
</body>
</html>
<script>

    function buy(ordernum) {

            $.post('${pageContext.request.contextPath}/order/orderServlet', {"op":"buy","opp":"1","ordernum":ordernum}, function(str){

            });
        alert("付款成功！！");
        window.location = "${pageContext.request.contextPath}/client/ClientServlet?op=category";
    }
</script>
